package com.common.vo;

//返回给前端的数据

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class Result<T>{



    //返回码： 0表示成功
    private Integer code;
    //返回描述
    private String message;

    //返回数据
    private T data;

    //分页查询的总记录数
    private Long count;

    public static Result<Object> success(){
        return   new Result(0,"success",null,null);

    }

    public static Result<Object> loginfalse(){
        return  new Result(-1,"用户名或密码错误",null,null);
    }









}
